// eslint-disable-next-line
/* eslint-disable */
import Vue from 'vue'
import Router from 'vue-router'
// import Login from "./views/Login.vue"
Vue.use(Router)

export default new Router({
	routes:[
		{
			name: 'login',
			path: '/',
			component: ()=>import("./views/Login.vue"),
			meta: {
				title: '登录'
			},
		},
		{
			name: 'register',
			path: '/register',
			component: ()=>import("./views/Register.vue"),
			meta: {
				title: "注册"
			}
		},
		{
			name: 'addinfo',
			path: '/addinfo',
			component: ()=>import("./views/AddInfo.vue"),
			meta: {
				title: '记账',
				requiresAuth: true,
			}
		},
		{
			name: 'editinfo',
			path: '/editinfo/:id',
			component: ()=>import("./views/EditInfo.vue"),
			meta: {
				title: '编辑',
				requiresAuth: true,
			}
		},
		{
			name: 'showinfo',
			path: '/showinfo',
			component: ()=>import("./views/ShowInfo.vue"),
			meta: {
				title: '显示信息',
				requiresAuth: true,
			}
		},
		{
			name: 'editriqi',
			path: '/editriji',
			component: ()=>import("./views/EditRiQi.vue"),
			meta: {
				title: '写日记',
				requiresAuth: true 
			}
		},
		{
			name: 'info',
			path: '/info/:id',
			component: ()=>import("./views/Info.vue"),
			meta: {
				title: '详细信息',
				requiresAuth: true 
			}
		}
	]
})